From d865fcaa3ffad2ec115434d2ae31534ad350da9a Mon Sep 17 00:00:00 2001 From: "kaf24@scramble.cl.cam.ac.uk" Date: Fri, 26 Nov 2004 18:21:39 +0000 Subject: [PATCH] bitkeeper revision 1.1159.187.20 (41a77433rez_BGuifdBbTI3Y34kiag) Deal with exception from guest context with real interrupts disabled. This can happen because IOPL != 0 and even a well-behaved guest may execute random BIOS code if it is a privileged hardware-controlling domain (e.g., DOM0 X server). --- xen/arch/x86/x86_32/entry.S | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xen/arch/x86/x86_32/entry.S b/xen/arch/x86/x86_32/entry.S index b235f710f9..32915e4a05 100644 --- a/xen/arch/x86/x86_32/entry.S +++ b/xen/arch/x86/x86_32/entry.S @@ -339,7 +339,7 @@ error_code: SET_XEN_SEGMENTS(a) testb $X86_EFLAGS_IF>>8,XREGS_eflags+1(%esp) jz exception_with_ints_disabled - sti # re-enable interrupts +1: sti # re-enable interrupts xorl %eax,%eax movw XREGS_entry_vector(%esp),%ax movl %esp,%edx @@ -354,8 +354,8 @@ error_code: exception_with_ints_disabled: movb XREGS_cs(%esp),%al - testb $3,%al # interrupts disabled outside Xen? - jnz FATAL_exception_with_ints_disabled + testb $3,%al # interrupts disabled outside Xen? + jnz 1b # it really does happen! (e.g., DOM0 X server) pushl XREGS_eip(%esp) call search_pre_exception_table addl $4,%esp -- 2.30.2